package com.project;

import java.io.IOException;
import java.io.InputStream;
import java.util.Map;

public class Request {
    /**客户端请求的路径*/
    private String sul;
    /**客户端请求的表单数据*/
    private Map<String,String> paraMap;
    public Request(InputStream in) {

        byte[]  by=new byte[1024];
        try {
            in.read(by);
            String str=new String(by).trim();
            this.sul=str.split("\\s+")[1].substring(1);






        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
public String getSul(){
        return sul;
}


    @Override
    public String toString() {
        return "Request{" +
                "sul='" + sul + '\'' +
                ", paraMap=" + paraMap +
                '}';
    }
}
